{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>标题</th>\n",
       "      <th>建筑面积</th>\n",
       "      <th>总价</th>\n",
       "      <th>户型</th>\n",
       "      <th>朝向</th>\n",
       "      <th>物 业 费</th>\n",
       "      <th>环比上月</th>\n",
       "      <th>张贴日期</th>\n",
       "      <th>产权性质</th>\n",
       "      <th>装修</th>\n",
       "      <th>楼层</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！</td>\n",
       "      <td>123.50</td>\n",
       "      <td>760</td>\n",
       "      <td>3室2厅0厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.5元/平米・月</td>\n",
       "      <td>↑1.44%</td>\n",
       "      <td>西元2017年4月12日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>豪华装修</td>\n",
       "      <td>低层</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化</td>\n",
       "      <td>86.00</td>\n",
       "      <td>76</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.8元/・月</td>\n",
       "      <td>↑4.08%</td>\n",
       "      <td>西元2017年4月13日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>精装修</td>\n",
       "      <td>中层</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>双高铁 不限贷 买一层送一层 送大露台 看房专车接送</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>3室2厅1厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>暂无资料</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>精装修</td>\n",
       "      <td>高层</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>暂无资料</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>简装修</td>\n",
       "      <td>中层</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看</td>\n",
       "      <td>66.61</td>\n",
       "      <td>285</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.8元/平米・月</td>\n",
       "      <td>↓2.62%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>个人产权</td>\n",
       "      <td>中装修</td>\n",
       "      <td>低层</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                               标题    建筑面积   总价        户型  朝向      物 业 费  \\\n",
       "0    资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！  123.50  760  3室2厅0厨2卫  南北  1.5元/平米・月   \n",
       "1     未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化   86.00   76  2室2厅1厨1卫  南北    1.8元/・月   \n",
       "2      双高铁 不限贷 买一层送一层 送大露台 看房专车接送   90.00   80  3室2厅1厨2卫  南北       暂无资料   \n",
       "3      坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户   90.00   80  2室1厅1厨1卫  南北       暂无资料   \n",
       "4  对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看   66.61  285  2室1厅1厨1卫   南  0.8元/平米・月   \n",
       "\n",
       "     环比上月          张贴日期  产权性质    装修  楼层  \n",
       "0  ↑1.44%  西元2017年4月12日   商品房  豪华装修  低层  \n",
       "1  ↑4.08%  西元2017年4月13日   商品房   精装修  中层  \n",
       "2  ↓0.01%  西元2017年4月14日   商品房   精装修  高层  \n",
       "3  ↓0.01%  西元2017年4月15日   商品房   简装修  中层  \n",
       "4  ↓2.62%  西元2017年4月16日  个人产权   中装修  低层  "
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#%ls Data\n",
    "\n",
    "import pandas\n",
    "df = pandas.read_excel('Data\\house_sample.xlsx')\n",
    "df.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0     7600000\n",
       "1      760000\n",
       "2      800000\n",
       "3      800000\n",
       "4     2850000\n",
       "5     2950000\n",
       "6     2400000\n",
       "7     4100000\n",
       "8     4000000\n",
       "9     2700000\n",
       "10    3000000\n",
       "11    2850000\n",
       "12    3400000\n",
       "13    3550000\n",
       "14    8500000\n",
       "15    3590000\n",
       "16    3600000\n",
       "17    6100000\n",
       "18    7700000\n",
       "19    2200000\n",
       "20    2360000\n",
       "21    2980000\n",
       "22    3250000\n",
       "23    4580000\n",
       "25    5600000\n",
       "26    6500000\n",
       "27    2000000\n",
       "28    2550000\n",
       "29    4500000\n",
       "Name: 总价, dtype: int64"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df['总价'] * 10000"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0     27.568098\n",
       "1      8.717798\n",
       "2      8.944272\n",
       "3      8.944272\n",
       "4     16.881943\n",
       "5     17.175564\n",
       "6     15.491933\n",
       "7     20.248457\n",
       "8     20.000000\n",
       "9     16.431677\n",
       "10    17.320508\n",
       "11    16.881943\n",
       "12    18.439089\n",
       "13    18.841444\n",
       "14    29.154759\n",
       "15    18.947295\n",
       "16    18.973666\n",
       "17    24.698178\n",
       "18    27.748874\n",
       "19    14.832397\n",
       "20    15.362291\n",
       "21    17.262677\n",
       "22    18.027756\n",
       "23    21.400935\n",
       "25    23.664319\n",
       "26    25.495098\n",
       "27    14.142136\n",
       "28    15.968719\n",
       "29    21.213203\n",
       "Name: 总价, dtype: float64"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import numpy as np\n",
    "np.sqrt(df['总价'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0     南北3室2厅0厨2卫\n",
       "1     南北2室2厅1厨1卫\n",
       "2     南北3室2厅1厨2卫\n",
       "3     南北2室1厅1厨1卫\n",
       "4      南2室1厅1厨1卫\n",
       "5     南北3室1厅1厨1卫\n",
       "6      南2室1厅1厨1卫\n",
       "7      南3室1厅1厨1卫\n",
       "8      南2室2厅1厨1卫\n",
       "9     南北1室1厅1厨1卫\n",
       "10    南北2室1厅1厨1卫\n",
       "11     南1室1厅1厨1卫\n",
       "12    南北1室1厅1厨1卫\n",
       "13    南北2室1厅1厨1卫\n",
       "14    南北3室2厅1厨2卫\n",
       "15     南2室1厅1厨1卫\n",
       "16     南2室1厅1厨1卫\n",
       "17    南北2室2厅1厨1卫\n",
       "18     南3室2厅0厨2卫\n",
       "19     南1室0厅1厨1卫\n",
       "20    南北2室2厅1厨1卫\n",
       "21     南1室2厅1厨1卫\n",
       "22     南1室2厅1厨1卫\n",
       "23    南北3室2厅1厨1卫\n",
       "25    南北3室2厅1厨2卫\n",
       "26     南2室2厅1厨2卫\n",
       "27     南1室1厅1厨1卫\n",
       "28    南北2室1厅1厨1卫\n",
       "29     南2室1厅0厨1卫\n",
       "dtype: object"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df['朝向'] + df['户型']"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>标题</th>\n",
       "      <th>建筑面积</th>\n",
       "      <th>总价</th>\n",
       "      <th>户型</th>\n",
       "      <th>朝向</th>\n",
       "      <th>物 业 费</th>\n",
       "      <th>环比上月</th>\n",
       "      <th>张贴日期</th>\n",
       "      <th>产权性质</th>\n",
       "      <th>均價</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！</td>\n",
       "      <td>123.50</td>\n",
       "      <td>760</td>\n",
       "      <td>3室2厅0厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.5元/平米・月</td>\n",
       "      <td>↑1.44%</td>\n",
       "      <td>西元2017年4月12日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>61538.461538</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化</td>\n",
       "      <td>86.00</td>\n",
       "      <td>76</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.8元/・月</td>\n",
       "      <td>↑4.08%</td>\n",
       "      <td>西元2017年4月13日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>8837.209302</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>双高铁 不限贷 买一层送一层 送大露台 看房专车接送</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>3室2厅1厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>暂无资料</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>8888.888889</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>暂无资料</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>商品房</td>\n",
       "      <td>8888.888889</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看</td>\n",
       "      <td>66.61</td>\n",
       "      <td>285</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.8元/平米・月</td>\n",
       "      <td>↓2.62%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>个人产权</td>\n",
       "      <td>42786.368413</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                               标题    建筑面积   总价        户型  朝向      物 业 费  \\\n",
       "0    资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！  123.50  760  3室2厅0厨2卫  南北  1.5元/平米・月   \n",
       "1     未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化   86.00   76  2室2厅1厨1卫  南北    1.8元/・月   \n",
       "2      双高铁 不限贷 买一层送一层 送大露台 看房专车接送   90.00   80  3室2厅1厨2卫  南北       暂无资料   \n",
       "3      坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户   90.00   80  2室1厅1厨1卫  南北       暂无资料   \n",
       "4  对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看   66.61  285  2室1厅1厨1卫   南  0.8元/平米・月   \n",
       "\n",
       "     环比上月          张贴日期  产权性质            均價  \n",
       "0  ↑1.44%  西元2017年4月12日   商品房  61538.461538  \n",
       "1  ↑4.08%  西元2017年4月13日   商品房   8837.209302  \n",
       "2  ↓0.01%  西元2017年4月14日   商品房   8888.888889  \n",
       "3  ↓0.01%  西元2017年4月15日   商品房   8888.888889  \n",
       "4  ↓2.62%  西元2017年4月16日  个人产权  42786.368413  "
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df['均價'] = df['总价'] * 10000 / df['建筑面积'] \n",
    "df.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'1.5'"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "s = '1.5元/平米・月'\n",
    "s.split('元')[0]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'1.5'"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def removeDollar(e):\n",
    "    return e.split('元')[0]\n",
    "removeDollar(s)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0      1.5\n",
       "1      1.8\n",
       "2     暂无资料\n",
       "3     暂无资料\n",
       "4      0.8\n",
       "5      0.6\n",
       "6      0.6\n",
       "7      1.4\n",
       "8     0.55\n",
       "9     暂无资料\n",
       "10     1.4\n",
       "11    暂无资料\n",
       "12     0.7\n",
       "13     0.5\n",
       "14    0.60\n",
       "15     1.2\n",
       "16     1.4\n",
       "17     1.5\n",
       "18     0.7\n",
       "19     1.4\n",
       "20     0.8\n",
       "21    1.65\n",
       "22    1.83\n",
       "23    1.25\n",
       "25    1.85\n",
       "26    2.30\n",
       "27     0.8\n",
       "28    0.95\n",
       "29     0.7\n",
       "Name: 物 业 费, dtype: object"
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df['物 业 费'].map(removeDollar)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "4"
      ]
     },
     "execution_count": 21,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def square(e):\n",
    "    return e * e \n",
    "square(2)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "4"
      ]
     },
     "execution_count": 22,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "square2 = lambda e: e * e\n",
    "square2(2)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0      1.5\n",
       "1      1.8\n",
       "2     暂无资料\n",
       "3     暂无资料\n",
       "4      0.8\n",
       "5      0.6\n",
       "6      0.6\n",
       "7      1.4\n",
       "8     0.55\n",
       "9     暂无资料\n",
       "10     1.4\n",
       "11    暂无资料\n",
       "12     0.7\n",
       "13     0.5\n",
       "14    0.60\n",
       "15     1.2\n",
       "16     1.4\n",
       "17     1.5\n",
       "18     0.7\n",
       "19     1.4\n",
       "20     0.8\n",
       "21    1.65\n",
       "22    1.83\n",
       "23    1.25\n",
       "25    1.85\n",
       "26    2.30\n",
       "27     0.8\n",
       "28    0.95\n",
       "29     0.7\n",
       "Name: 物 业 费, dtype: object"
      ]
     },
     "execution_count": 23,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def removeDollar(e):\n",
    "    return e.split('元')[0]\n",
    "\n",
    "df['物 业 费'].map(lambda e: e.split('元')[0])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>First</th>\n",
       "      <th>Second</th>\n",
       "      <th>Third</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>60</td>\n",
       "      <td>70</td>\n",
       "      <td>50</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>80</td>\n",
       "      <td>79</td>\n",
       "      <td>68</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>63</td>\n",
       "      <td>66</td>\n",
       "      <td>82</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   First  Second  Third\n",
       "0     60      70     50\n",
       "1     80      79     68\n",
       "2     63      66     82"
      ]
     },
     "execution_count": 26,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df = pandas.DataFrame([\n",
    "                    [60,70,50],\\\n",
    "                    [80,79,68],\\\n",
    "                    [63,66,82]], columns = ['First', 'Second', 'Third'])\n",
    "df"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 28,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "First     20\n",
       "Second    13\n",
       "Third     32\n",
       "dtype: int64"
      ]
     },
     "execution_count": 28,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.apply(lambda e: e.max() - e.min())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "?df.apply"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0    20\n",
       "1    12\n",
       "2    19\n",
       "dtype: int64"
      ]
     },
     "execution_count": 30,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.apply(lambda e: e.max() - e.min(), axis = 1)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>标题</th>\n",
       "      <th>建筑面积</th>\n",
       "      <th>总价</th>\n",
       "      <th>户型</th>\n",
       "      <th>朝向</th>\n",
       "      <th>物 业 费</th>\n",
       "      <th>环比上月</th>\n",
       "      <th>张贴日期</th>\n",
       "      <th>产权性质</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！</td>\n",
       "      <td>123.50</td>\n",
       "      <td>760</td>\n",
       "      <td>3室2厅0厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.5元/平米・月</td>\n",
       "      <td>↑1.44%</td>\n",
       "      <td>西元2017年4月12日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化</td>\n",
       "      <td>86.00</td>\n",
       "      <td>76</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.8元/・月</td>\n",
       "      <td>↑4.08%</td>\n",
       "      <td>西元2017年4月13日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>双高铁 不限贷 买一层送一层 送大露台 看房专车接送</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>3室2厅1厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>暂无资料</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>暂无资料</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看</td>\n",
       "      <td>66.61</td>\n",
       "      <td>285</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.8元/平米・月</td>\n",
       "      <td>↓2.62%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                               标题    建筑面积   总价        户型  朝向      物 业 费  \\\n",
       "0    资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！  123.50  760  3室2厅0厨2卫  南北  1.5元/平米・月   \n",
       "1     未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化   86.00   76  2室2厅1厨1卫  南北    1.8元/・月   \n",
       "2      双高铁 不限贷 买一层送一层 送大露台 看房专车接送   90.00   80  3室2厅1厨2卫  南北       暂无资料   \n",
       "3      坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户   90.00   80  2室1厅1厨1卫  南北       暂无资料   \n",
       "4  对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看   66.61  285  2室1厅1厨1卫   南  0.8元/平米・月   \n",
       "\n",
       "     环比上月          张贴日期  产权性质  \n",
       "0  ↑1.44%  西元2017年4月12日   商品房  \n",
       "1  ↑4.08%  西元2017年4月13日   商品房  \n",
       "2  ↓0.01%  西元2017年4月14日   商品房  \n",
       "3  ↓0.01%  西元2017年4月15日   商品房  \n",
       "4  ↓2.62%  西元2017年4月16日  个人产权  "
      ]
     },
     "execution_count": 32,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#%ls Data\n",
    "\n",
    "import pandas\n",
    "df = pandas.read_excel('house_sample.xlsx')\n",
    "df.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {
    "collapsed": false
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "def convertNaN(e):\n",
    "    if e == '暂无资料':\n",
    "        return np.nan\n",
    "    else:\n",
    "        return e\n",
    "    \n",
    "#df.applymap(convertNaN)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>标题</th>\n",
       "      <th>建筑面积</th>\n",
       "      <th>总价</th>\n",
       "      <th>户型</th>\n",
       "      <th>朝向</th>\n",
       "      <th>物 业 费</th>\n",
       "      <th>环比上月</th>\n",
       "      <th>张贴日期</th>\n",
       "      <th>产权性质</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！</td>\n",
       "      <td>123.50</td>\n",
       "      <td>760</td>\n",
       "      <td>3室2厅0厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.5元/平米・月</td>\n",
       "      <td>↑1.44%</td>\n",
       "      <td>西元2017年4月12日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化</td>\n",
       "      <td>86.00</td>\n",
       "      <td>76</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.8元/・月</td>\n",
       "      <td>↑4.08%</td>\n",
       "      <td>西元2017年4月13日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>双高铁 不限贷 买一层送一层 送大露台 看房专车接送</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>3室2厅1厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>NaN</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户</td>\n",
       "      <td>90.00</td>\n",
       "      <td>80</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>NaN</td>\n",
       "      <td>↓0.01%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看</td>\n",
       "      <td>66.61</td>\n",
       "      <td>285</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.8元/平米・月</td>\n",
       "      <td>↓2.62%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>精装三房，精装修全送， 边套全明，小区中心位置，采光无遮挡！</td>\n",
       "      <td>72.00</td>\n",
       "      <td>295</td>\n",
       "      <td>3室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>0.6元/平米・月</td>\n",
       "      <td>↑1.64%</td>\n",
       "      <td>西元2017年4月17日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>精装两年 楼下有固定车位 接受置换 中间楼层 双南户型 底价诚售</td>\n",
       "      <td>65.58</td>\n",
       "      <td>240</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.6元/平米・月</td>\n",
       "      <td>↓1.52%</td>\n",
       "      <td>西元2017年4月18日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>此房2楼的 房东价格可谈 价格真实产权清晰</td>\n",
       "      <td>73.35</td>\n",
       "      <td>410</td>\n",
       "      <td>3室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>1.4元/平米・月</td>\n",
       "      <td>↓0.39%</td>\n",
       "      <td>西元2017年4月19日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>浦发绿城靠近11号线 浦三路站 400万 2房2厅1卫</td>\n",
       "      <td>72.93</td>\n",
       "      <td>400</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.55元/平米・月</td>\n",
       "      <td>↓0.25%</td>\n",
       "      <td>西元2017年4月20日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>长桥六村！一房一厅户型正气南北通透！对口实验小学！好房</td>\n",
       "      <td>47.00</td>\n",
       "      <td>270</td>\n",
       "      <td>1室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>NaN</td>\n",
       "      <td>↓0.79%</td>\n",
       "      <td>西元2017年4月21日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>此房6楼的 房东价格可谈 价格真实 诚意出售</td>\n",
       "      <td>48.55</td>\n",
       "      <td>300</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.4元/平米・月</td>\n",
       "      <td>↓0.39%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>此房5楼的 房东价格可谈 精装修 价格真实诚意出售</td>\n",
       "      <td>44.00</td>\n",
       "      <td>285</td>\n",
       "      <td>1室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>NaN</td>\n",
       "      <td>↓0.79%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>此房5楼的，为数不多的一房，为数不多的5楼的。</td>\n",
       "      <td>55.00</td>\n",
       "      <td>340</td>\n",
       "      <td>1室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>0.7元/平米・月</td>\n",
       "      <td>↑0.92%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>13</th>\n",
       "      <td>舒乐小区、对口上实附小、小区门口、房东急售、看房有钥匙</td>\n",
       "      <td>61.00</td>\n",
       "      <td>355</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>0.5元/平米・月</td>\n",
       "      <td>↓0.64%</td>\n",
       "      <td>西元2017年4月17日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>天秀苑蕞低价，6楼的4楼、看房我们店有钥匙</td>\n",
       "      <td>115.00</td>\n",
       "      <td>850</td>\n",
       "      <td>3室2厅1厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>0.60元/平米・月</td>\n",
       "      <td>↓0.79%</td>\n",
       "      <td>西元2017年4月18日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15</th>\n",
       "      <td>结婚在我手上买的婚房，现在生二胎要买大的，老房东找我价格好谈</td>\n",
       "      <td>67.00</td>\n",
       "      <td>359</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>1.2元/平米・月</td>\n",
       "      <td>↓1.92%</td>\n",
       "      <td>西元2017年4月19日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>精装修的房子，业主置换已经看中房子，看房家里都是有人</td>\n",
       "      <td>67.00</td>\n",
       "      <td>360</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>1.4元/平米・月</td>\n",
       "      <td>↓0.39%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>17</th>\n",
       "      <td>靠河的 3楼的 满五不唯yi 产权清晰，户口好迁，诚意出售</td>\n",
       "      <td>89.00</td>\n",
       "      <td>610</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.5元/平米・月</td>\n",
       "      <td>↓2.38%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>叔叔阿姨是华理的老师，叔叔是个爱收集古玩的人，房子自住的</td>\n",
       "      <td>121.80</td>\n",
       "      <td>770</td>\n",
       "      <td>3室2厅0厨2卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.7元/平米・月</td>\n",
       "      <td>↑0.92%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>19</th>\n",
       "      <td>此房5楼的 房东价格可谈 诚意出售 价格真实</td>\n",
       "      <td>33.00</td>\n",
       "      <td>220</td>\n",
       "      <td>1室0厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>1.4元/平米・月</td>\n",
       "      <td>↓0.39%</td>\n",
       "      <td>西元2017年4月17日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>景谷苑三期，04年小区，急降20万，一梯两户，南北直通，房东急售</td>\n",
       "      <td>70.00</td>\n",
       "      <td>236</td>\n",
       "      <td>2室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>0.8元/平米・月</td>\n",
       "      <td>↓3.01%</td>\n",
       "      <td>西元2017年4月18日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td>9号线地铁房，高品质小区，诚意卖，小区央位，送装修拎包入住。</td>\n",
       "      <td>58.00</td>\n",
       "      <td>298</td>\n",
       "      <td>1室2厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>1.65元/平米・月</td>\n",
       "      <td>↓3.5%</td>\n",
       "      <td>西元2017年4月19日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td>9号线，低密度高档小区，执掌大虹桥，连接徐家汇，高性价比。</td>\n",
       "      <td>65.00</td>\n",
       "      <td>325</td>\n",
       "      <td>1室2厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>1.83元/・月</td>\n",
       "      <td>↓3.06%</td>\n",
       "      <td>西元2017年4月17日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>垫高一楼，不潮湿，近9号线，九亭商业街，周边成熟，交通便利。</td>\n",
       "      <td>118.00</td>\n",
       "      <td>458</td>\n",
       "      <td>3室2厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.25元/平米・月</td>\n",
       "      <td>↓2.49%</td>\n",
       "      <td>西元2017年4月18日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td>9号线旁，大虹桥，国展中心旁，双轨交汇，3+1大平层，带产权车库</td>\n",
       "      <td>132.00</td>\n",
       "      <td>560</td>\n",
       "      <td>3室2厅1厨2卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>1.85元/平米・月</td>\n",
       "      <td>↓1.75%</td>\n",
       "      <td>西元2017年4月14日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>汇翠花园位于徐家汇万体馆旁，环境优美，闹中取静，精装，送车位</td>\n",
       "      <td>108.00</td>\n",
       "      <td>650</td>\n",
       "      <td>2室2厅1厨2卫</td>\n",
       "      <td>南</td>\n",
       "      <td>2.30元/平米・月</td>\n",
       "      <td>↑1.28%</td>\n",
       "      <td>西元2017年4月15日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>近地铁 一房一厅 厨房在过道 总价低 近陆家嘴</td>\n",
       "      <td>38.00</td>\n",
       "      <td>200</td>\n",
       "      <td>1室1厅1厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.8元/平米・月</td>\n",
       "      <td>↓2.68%</td>\n",
       "      <td>西元2017年4月16日</td>\n",
       "      <td>商品房</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>三年前装修，清爽干净，双南全明，不靠变电站，稀售近双轨方便</td>\n",
       "      <td>64.00</td>\n",
       "      <td>255</td>\n",
       "      <td>2室1厅1厨1卫</td>\n",
       "      <td>南北</td>\n",
       "      <td>0.95元/平米・月</td>\n",
       "      <td>↓4.78%</td>\n",
       "      <td>西元2017年4月17日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td>2婚装双南两房 全送家具家电 满五年省税 双轨6/12相临</td>\n",
       "      <td>69.90</td>\n",
       "      <td>450</td>\n",
       "      <td>2室1厅0厨1卫</td>\n",
       "      <td>南</td>\n",
       "      <td>0.7元/平米・月</td>\n",
       "      <td>↑21.17%</td>\n",
       "      <td>西元2017年4月18日</td>\n",
       "      <td>个人产权</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                  标题    建筑面积   总价        户型  朝向       物 业 费  \\\n",
       "0       资深经纪上海人：稀缺3房，南北通透采光好，房东急需用钱！  123.50  760  3室2厅0厨2卫  南北   1.5元/平米・月   \n",
       "1        未来规划小上海，精装带地暖，养老，亲子，旅游度假一体化   86.00   76  2室2厅1厨1卫  南北     1.8元/・月   \n",
       "2         双高铁 不限贷 买一层送一层 送大露台 看房专车接送   90.00   80  3室2厅1厨2卫  南北         NaN   \n",
       "3         坐拥嘉兴海宁双轨 享受市区配套 现房值得拥有 可落户   90.00   80  2室1厅1厨1卫  南北         NaN   \n",
       "4     对口明强校区，精装两房税费少，位置安静，媲美园艺新村，随时看   66.61  285  2室1厅1厨1卫   南   0.8元/平米・月   \n",
       "5     精装三房，精装修全送， 边套全明，小区中心位置，采光无遮挡！   72.00  295  3室1厅1厨1卫  南北   0.6元/平米・月   \n",
       "6   精装两年 楼下有固定车位 接受置换 中间楼层 双南户型 底价诚售   65.58  240  2室1厅1厨1卫   南   0.6元/平米・月   \n",
       "7              此房2楼的 房东价格可谈 价格真实产权清晰   73.35  410  3室1厅1厨1卫   南   1.4元/平米・月   \n",
       "8        浦发绿城靠近11号线 浦三路站 400万 2房2厅1卫   72.93  400  2室2厅1厨1卫   南  0.55元/平米・月   \n",
       "9        长桥六村！一房一厅户型正气南北通透！对口实验小学！好房   47.00  270  1室1厅1厨1卫  南北         NaN   \n",
       "10            此房6楼的 房东价格可谈 价格真实 诚意出售   48.55  300  2室1厅1厨1卫  南北   1.4元/平米・月   \n",
       "11         此房5楼的 房东价格可谈 精装修 价格真实诚意出售   44.00  285  1室1厅1厨1卫   南         NaN   \n",
       "12           此房5楼的，为数不多的一房，为数不多的5楼的。   55.00  340  1室1厅1厨1卫  南北   0.7元/平米・月   \n",
       "13       舒乐小区、对口上实附小、小区门口、房东急售、看房有钥匙   61.00  355  2室1厅1厨1卫  南北   0.5元/平米・月   \n",
       "14             天秀苑蕞低价，6楼的4楼、看房我们店有钥匙  115.00  850  3室2厅1厨2卫  南北  0.60元/平米・月   \n",
       "15    结婚在我手上买的婚房，现在生二胎要买大的，老房东找我价格好谈   67.00  359  2室1厅1厨1卫   南   1.2元/平米・月   \n",
       "16        精装修的房子，业主置换已经看中房子，看房家里都是有人   67.00  360  2室1厅1厨1卫   南   1.4元/平米・月   \n",
       "17     靠河的 3楼的 满五不唯yi 产权清晰，户口好迁，诚意出售   89.00  610  2室2厅1厨1卫  南北   1.5元/平米・月   \n",
       "18      叔叔阿姨是华理的老师，叔叔是个爱收集古玩的人，房子自住的  121.80  770  3室2厅0厨2卫   南   0.7元/平米・月   \n",
       "19            此房5楼的 房东价格可谈 诚意出售 价格真实   33.00  220  1室0厅1厨1卫   南   1.4元/平米・月   \n",
       "20  景谷苑三期，04年小区，急降20万，一梯两户，南北直通，房东急售   70.00  236  2室2厅1厨1卫  南北   0.8元/平米・月   \n",
       "21    9号线地铁房，高品质小区，诚意卖，小区央位，送装修拎包入住。   58.00  298  1室2厅1厨1卫   南  1.65元/平米・月   \n",
       "22     9号线，低密度高档小区，执掌大虹桥，连接徐家汇，高性价比。   65.00  325  1室2厅1厨1卫   南    1.83元/・月   \n",
       "23    垫高一楼，不潮湿，近9号线，九亭商业街，周边成熟，交通便利。  118.00  458  3室2厅1厨1卫  南北  1.25元/平米・月   \n",
       "25  9号线旁，大虹桥，国展中心旁，双轨交汇，3+1大平层，带产权车库  132.00  560  3室2厅1厨2卫  南北  1.85元/平米・月   \n",
       "26    汇翠花园位于徐家汇万体馆旁，环境优美，闹中取静，精装，送车位  108.00  650  2室2厅1厨2卫   南  2.30元/平米・月   \n",
       "27           近地铁 一房一厅 厨房在过道 总价低 近陆家嘴   38.00  200  1室1厅1厨1卫   南   0.8元/平米・月   \n",
       "28     三年前装修，清爽干净，双南全明，不靠变电站，稀售近双轨方便   64.00  255  2室1厅1厨1卫  南北  0.95元/平米・月   \n",
       "29     2婚装双南两房 全送家具家电 满五年省税 双轨6/12相临   69.90  450  2室1厅0厨1卫   南   0.7元/平米・月   \n",
       "\n",
       "       环比上月          张贴日期  产权性质  \n",
       "0    ↑1.44%  西元2017年4月12日   商品房  \n",
       "1    ↑4.08%  西元2017年4月13日   商品房  \n",
       "2    ↓0.01%  西元2017年4月14日   商品房  \n",
       "3    ↓0.01%  西元2017年4月15日   商品房  \n",
       "4    ↓2.62%  西元2017年4月16日  个人产权  \n",
       "5    ↑1.64%  西元2017年4月17日  个人产权  \n",
       "6    ↓1.52%  西元2017年4月18日  个人产权  \n",
       "7    ↓0.39%  西元2017年4月19日   商品房  \n",
       "8    ↓0.25%  西元2017年4月20日   商品房  \n",
       "9    ↓0.79%  西元2017年4月21日   商品房  \n",
       "10   ↓0.39%  西元2017年4月14日   商品房  \n",
       "11   ↓0.79%  西元2017年4月15日   商品房  \n",
       "12   ↑0.92%  西元2017年4月16日   商品房  \n",
       "13   ↓0.64%  西元2017年4月17日   商品房  \n",
       "14   ↓0.79%  西元2017年4月18日   商品房  \n",
       "15   ↓1.92%  西元2017年4月19日   商品房  \n",
       "16   ↓0.39%  西元2017年4月14日   商品房  \n",
       "17   ↓2.38%  西元2017年4月15日   商品房  \n",
       "18   ↑0.92%  西元2017年4月16日   商品房  \n",
       "19   ↓0.39%  西元2017年4月17日   商品房  \n",
       "20   ↓3.01%  西元2017年4月18日  个人产权  \n",
       "21    ↓3.5%  西元2017年4月19日  个人产权  \n",
       "22   ↓3.06%  西元2017年4月17日  个人产权  \n",
       "23   ↓2.49%  西元2017年4月18日  个人产权  \n",
       "25   ↓1.75%  西元2017年4月14日  个人产权  \n",
       "26   ↑1.28%  西元2017年4月15日  个人产权  \n",
       "27   ↓2.68%  西元2017年4月16日   商品房  \n",
       "28   ↓4.78%  西元2017年4月17日  个人产权  \n",
       "29  ↑21.17%  西元2017年4月18日  个人产权  "
      ]
     },
     "execution_count": 36,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.applymap(lambda e: np.nan if e == '暂无资料' else e)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.0"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
